<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
	<title>行程顾问管理</title>
	<meta name="decorator" content="default"/>
	<script type="text/javascript">
	$(document).ready(function() {
		$("#btnSure").click(function(){
			top.$.jBox.confirm("确认执行该操作么？","系统提示",function(v,h,f){
				if(v=="ok"){
					$("#searchForm").attr("action","/quickdeer/a/trip/tTrip/sure?tripCounselorId=${tripCounselorId}");
					$("#searchForm").submit();
				}
			},{buttonsFocus:1});
			top.$('.jbox-body .jbox-icon').css('top','55px');
		});
	});
		
		function page(n,s){
			$("#pageNo").val(n);
			$("#pageSize").val(s);
			$("#searchForm").submit();
			return false;
		}
		
	</script>
</head>
<body>
	<ul class="nav nav-tabs">
		<li ><a href="${ctx}/trip/tTrip/">行程顾问列表</a></li>
		<li class="active"><a href="javascript:">行程规划列表</a></li>
		<li ><a href="${ctx}/trip/tTrip/add?tripCounselorId=${tripCounselorId}">添加</a></li>
	</ul>
	 <form:form id="searchForm" action="${ctx}/orders/tOrders/allOrderList"
		modelAttribute="TOrders" method="post" class="breadcrumb form-search">
		
		<input id="btnSure" class="btn btn-primary" type="button" value="确认生效"/>
	</form:form>
	<sys:message content="${message}"/>
	
	<table id="contentTable" class="table table-striped table-bordered table-condensed">
		<thead>
			<tr>
				<th>天数</th>
				<th>路线</th>
				<th>餐饮</th>
				<th>距离</th>
				<th>住宿</th>
				<th>创建时间</th>
				<th>操作</th>
			</tr>
		</thead>
		<c:forEach items="${list}" var="TripCounselorInfo">
			<tr>
				<td>${TripCounselorInfo.day}</td>
				<td>${TripCounselorInfo.route} </td>
				<td>${TripCounselorInfo.meals }</td>
				<td>${TripCounselorInfo.distance }</td>
				<td>${TripCounselorInfo.hotel }</td>
				<td><fmt:formatDate value="${TripCounselorInfo.previewCreateTime}" pattern="yyyy-MM-dd" /></td>
				<td>
				    <span ><a  href="${ctx}/trip/tTrip/edit?tripPreviewId=${TripCounselorInfo.tripPreviewId} ">修改</a></span>
					<span ><a  href="${ctx}/trip/tTrip/del?tripPreviewId=${TripCounselorInfo.tripPreviewId}&tripCounselorId=${TripCounselorInfo.tripCounselorId} ">删除</a></span>
				</td>
			</tr>
		</c:forEach>
		</tbody>
	</table>
</body>
</html>